
#pragma once

#include <gl/glew.h>
#include <iostream>
#include <string>
#include <fstream>
using namespace std;

#include "glm\glm.hpp"
#include "glm\ext.hpp"
using namespace glm;


#define UNDEF			-1

enum VertexAttributeIndexes
{
	ATTRIB_POSITION,
	ATTRIB_COLOR,
	ATTRIB_NORMAL,
	ATTRIB_TEXCOORD0,
	ATTRIB_TEXCOORD1,
	ATTRIB_TEXCOORD2,
	ATTRIB_TEXCOORD3,
	ATTRIB_TEXCOORD4,
	ATTRIB_COUNT
};

#define SINGLETON(type)	public: \
							static type& instance() {static type inst; return inst; } \
						private: \
							type(const type&); \
							virtual ~type() {}

#define DEBUG_IMPL		cout<<"DEBUG_IMPL: "<<__FILE__<<", "<<__LINE__<<endl;
#define GL_CHECK_ERROR	for (GLenum err = glGetError(); err != GL_NO_ERROR; ) { cout<<"GL_CHECK_ERROR: "<<err<<endl; err = glGetError(); }

#define BUFFER_OFFSET(i)	((char *)NULL + (i))

typedef vec4 ColorRGBA;










